package com.lara.rst;

class W{
	int i;
	String s1;
	W(int i,String s1){
		this.i=i;
		this.s1=s1;
		
	}
	public int hashCode(){
		String str=Integer.toString(i);
		int hash=str.hashCode();
		hash=hash+s1.hashCode();
		return hash;
	}
}
public class Manager15 {
public static void main(String[] args) {
W w1=new W(10, "deepak");
W w2=new W(10, "deepak");
System.out.println(w1);
System.out.println(w2);
System.out.println(w1==w2);
System.out.println(w1.equals(w2));
System.out.println(w1.hashCode());
System.out.println(w2.hashCode());

}
}
